Skip to content

docs: correct testing documentation and commands; clean legacy references#95

Open
mikemaccana wants to merge 1 commit into
mainfrom
audit/fix-testing-docs-legacy
Open

docs: correct testing documentation and commands; clean legacy references#95
mikemaccana wants to merge 1 commit into
mainfrom
audit/fix-testing-docs-legacy

Conversation

@mikemaccana

Copy link
Copy Markdown
Collaborator

Summary

This PR executes three focused items from the solana-program-examples audit vs. the latest solana-finance skill (https://github.com/quicknode/solana-finance-skill):

  • Fix testing documentation and commands: CONTRIBUTING.md, root README, and many anchor example READMEs now correctly document the actual commands and layout.

    • Anchor: anchor test (or cargo test) from the .../anchor/ dir. Tests live in programs/<name>/tests/.
    • Quasar: cargo test (or quasar test). Tests live in src/tests.rs (per Quasar.toml).
    • Removed the incorrect universal "run pnpm test from the subdir" guidance and fixed prerequisite text.
  • Enforce transfer_checked uniformly in Quasar token paths (documentation + prep): Investigation confirmed quasar_spl .transfer(...) is the raw/unchecked form while .transfer_checked(..., mint, ..., decimals) is the safe equivalent (already used correctly in lending and external-delegate Quasar code).

    • Ready-to-apply patches for the finance examples (escrow, token-swap, token-fundraiser) plus the required Accounts changes for the fundraiser mint are recorded in the committed ACTIVE-AUDIT-ITEMS.md.
    • Anchor twins already use transfer_checked.
  • Clean legacy / inconsistent artifacts (markdown portion): Removed active references and links to the deprecated solana-developers/program-examples (and professional-education) in credits and docs per the skill rules. ACTIVE-AUDIT-ITEMS.md contains the exact steps + commands for deleting the orphan tokens/.../allow-block-list-token/anchor/tests-rs/ directory and stripping stale bankrun/validator comments from a few Anchor.toml files.

All landed changes are documentation / reference cleanup. The ACTIVE-AUDIT-ITEMS.md file committed with the PR serves as the detailed record and patch source for the remaining non-markdown parts of the three items.

Changes

  • 16 files (15 docs + 1 new audit scope file)
  • Pre-commit biome formatting applied cleanly.
  • No program behavior changes.

Test plan

  • Commit succeeded with lint-staged + biome --write on all changed files.
  • From updated anchor directories (e.g. basics/counter/anchor, finance/token-swap/anchor, basics/hello-solana/anchor): anchor build && anchor test (or plain cargo test).
  • Confirm Quasar READMEs (counter, escrow, etc.) still correctly say cargo test.
  • When applying the prepared patches from ACTIVE-AUDIT-ITEMS.md: run the relevant cargo test (Quasar finance) and anchor test for any touched tomls.
  • Root pnpm check / pnpm lint (biome) at repo level if desired.
  • Review that no references to the old solana-developers program-examples remain in active docs.

✅ Testing docs/commands aligned
✅ Legacy references cleaned (markdown)
❌ (Prepared) Quasar transfer_checked source changes + orphan dir + toml comments — patches + exact commands in ACTIVE-AUDIT-ITEMS.md

Made with Cursor

@mikemaccana mikemaccana force-pushed the audit/fix-testing-docs-legacy branch 3 times, most recently from ae3e0b9 to 7c0c562 Compare July 2, 2026 20:33
…an legacy references

- Standardize Anchor testing instructions on one command: `anchor test`.
- Remove alternative `cargo test` suggestions from CONTRIBUTING.md and Anchor READMEs (counter, hello-solana, close-account, transfer-sol, rent, realloc, token-swap, transfer-tokens, create-token, program-derived-addresses, etc.).
- Update root README framework description and getting-started text for consistency.
- Remove ACTIVE-AUDIT-ITEMS.md from this PR (per request).
- Preserve contributor credits in Pinocchio examples (e.g. @MarkFeder ports from solana-developers/program-examples) while cleaning other stale references.

Co-authored-by: Cursor <cursoragent@cursor.com>
@mikemaccana mikemaccana force-pushed the audit/fix-testing-docs-legacy branch from 7c0c562 to f8dbbc2 Compare July 2, 2026 21:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant